package com.tmsps.ne4Weixin.utils;

import java.util.Map;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * @author zhangwei 396033084@qq.com XMLParser
 */
public class XMLParser {
	protected static Logger log = LoggerFactory.getLogger(WeixinUtil.class);

	/**
	 * @author zhangwei 396033084@qq.com 将xml文件转成map
	 */
	public static Map<String, String> getXmlToMap(String xml) {
		if (StrUtil.isBlank(xml)) {
			log.error("XML PARAMETER ILLEGAL !!!!!!");
			throw new IllegalArgumentException();
		} else {
			return XmlHelper.of(xml.trim()).toLowerCaseMap();
		}
	}
}
